<ion-view view-title="优惠券详情"  hide-tabs="true" >
  <!-- 头部 -->
  <ion-header-bar align-title="center" class="bar-positive">
    <div class="buttons" >
       <button class=" button-go-back" ng-click="goback()"><i class="icon ion-chevron-left"></i></button> 
    </div>
    <h1 class="title">优惠券详情</h1>
  </ion-header-bar> 
  <ion-content id="coppon_detail" [scroll="true"] [overflow-scroll="true"] class="APP_BG_color">
    <div style="padding:15px;">
        <div class="coppon">
            <img ng-src="img/yhqbg.png" alt="bg" class="bg">
            <img ng-src="{{coupons_details.imageUrl}}" alt="logo" class="logo">
            <div class="info">
                <p>{{coupons_details.couponInfo['couponName']}}</p>
                <h4>{{coupons_details.couponInfo['couponPrice']}}元代金券</h4>
            </div>
        </div>
    </div>
    <div  class="info_box">
        <p class="title">
            {{coupons_details.couponInfo['couponName']}}
            <!-- 母婴超值100元代金券 -->
        </p>
        <p class="pay">
            {{coupons_details.payPoint | number:0}}<small>积分+</small>{{coupons_details.payMoney}}<small>元</small>
        </p>
        <p style="font-size:14px;font-family:PingFangSC-Medium;color:rgba(158,158,158,1);line-height:20px;">商品描述：</p>
        <p class="lists">
            <span>金额：</span>
            {{coupons_details.couponInfo.couponPrice}}元
        </p>
        <p class="lists">
            <span>使用规则：</span>
            {{coupons_details.couponInfo.useThreshold | rule}}
        </p>
        <p class="lists">
            <span>有效时间：</span>
            {{coupons_details.couponInfo.beginTime }}至{{coupons_details.couponInfo.endTime}}
        </p>
        <p class="lists">
            <span>生效时间：</span>
            {{coupons_details.couponInfo.availableType | sxsj}}
            <!-- 即时生效 -->
        </p>
        <p class="lists">
            <span>适用品牌：</span>
            {{coupons_details.couponInfo['scope']}}
            <!-- 象宝宝、威尔贝鲁、妙心、全棉时代 -->
        </p> 
        <!-- <p class="lists">
            <span></span>
            <span>查看全部</span>
        </p>  -->
        <p class="lists">
            <span>使用须知：</span>
           <a style="color:#212121" ng-bind-html="coupons_details.couponInfo.useArticles"></a>
        </p>
        <div class="able">
            可购买的会员等级：
        </div>
        <div class="grade">
            {{coupons_details.levels}}
            <!-- 金卡、白金卡、钻石卡 -->
        </div>
    </div>
    <p class="btn">
         <button ng-click="go_confirm()">我要兑换</button> 
    </p>
    <!--登录模块-->
    <script id="templates/modal.html" type="text/ng-template">
      <ion-modal-view id="QR_page">
        <ion-header-bar class="bar bar-header padding">
            <h1 class="title">
            <button class="button button-clear button-primary" ng-click=" modal.hide()">关闭</button>
            {{m_title}}
            </h1>
        </ion-header-bar>
        <ion-content class="padding">
            <!-- 登录模块 -->
            <div id="login" ng-if="display_login">
              <div class="button-bar sub_header_list">
                  <a class="button button-clear" ng-click="changeModel(0)" ng-class="{true:'selected',false:'unselected'}[show_M == 0]">验证码登录</a>
                  <a class="button button-clear" ng-click="changeModel(1)" ng-class="{true:'selected',false:'unselected'}[show_M == 1]">密码登录</a>
              </div>
              <form action="" ng-if="pwd_login_2" ><!--常规登录-->
                  <p class="no_pwd">若忘记密码，请使用验证码登录</p>
                  <div class="login_list">
                    <input type="text" placeholder="输入手机号" ng-class="{'phone':true,'e_act':true}" ng-model="n_user_info.user_num" ng-focus="phone_test()">
                    <span class="notice">{{reg_notice_phone}}</span>
                  </div>
                  <div class="login_list" style="position:relative;">
                    <input id="pwd" type="password" placeholder="请输入密码" ng-class="{'phone':true,'e_act':true}" ng-model="n_user_info.user_pwd" ng-focus="verification_test()">
                    <span class="show" ng-click="show_pwd()">{{show_pwd_value}}</span>
                    <span class="notice" >{{reg_notice_pwd}}
                      <span class="remember_pwd" >
                         <!-- ng-checked="ischecked"  -->
                        <input type="checkbox" hidden  ng-model="ischecked" ng-checked="ischecked" id="mar"/>
                        <label ng-click="toggle_pwd()">记住密码</label>
                      </span>
                    </span>
                  </div>
                  <div class="login_list">
                    <button type="button" id = "login_btn_1" ng-class="{'login_btn_def':true,'login_btn_act':true}" ng-click = "login_pwd()">登 &nbsp; 录</button>
                    <span class="notice">{{pwd_login_res}}</span>
                  </div>
              </form>

              <form action="" ng-if="test_code_login_2"><!--快捷登录-->
                  <p class="no_pwd"></p>
                  <div class="login_list" style="position:relative;border-color:#A58648">
                       
                      <div class="item item-input item-select" style="width:65px;position:absolute;top:0px;left:0px;padding:0;height:30px;">
                        <!-- 86中国 82韩国  65新加坡 -->
                        <select style="max-width:100%;" id = 'coupon_DL_area'>
                          <option value = '86'>+86</option>
                          <option value = '82'>+82</option>
                          <option value = '65'>+65</option>
                        </select>
                      </div>

                      <input type="text" style="padding-left:74px;" placeholder="输入手机号" ng-class="{'phone':true,'e_act':true}" ng-model="user_info.user_num" ng-focus="phone_test()">
                    <span class="notice" >{{phone_tc}}</span>
                  </div>
                  <div class="login_list">
                    <input type="text"placeholder="输入验证码" ng-class="{'num':true,'e_act':true}"ng-model="user_info.test_code" ng-focus="verification_test()">
                    <a ng-click="get_test_code($event)" ng-bind="captcha.paracont" class="test_btn">发送验证码</a>
                    <span class="notice" >{{test_code_tc}}  </span>
                  </div>
                  <div class="login_list">
                    <button type="button" id = "login_btn" ng-class="{'login_btn_def':true,'login_btn_act':true}" ng-click = "LOGIN()">登 &nbsp; 录</button>
                  </div>
              </form>
              <p class="change">
                  还不是会员，<span style="color:#A58648;"ng-click="change_page(1)" >马上注册</span>
              </p>
            </div>
            <!-- 注册模块 -->
            <div id="register" ng-if="display_register">
               <form action="" style="margin-top:30px;">
                <div class="login_list "style="position:relative;border-color:#A58648">
                       
                      <div class="item item-input item-select" style="width:65px;position:absolute;top:0px;left:0px;padding:0;height:30px;">
                        <!-- 86中国 82韩国  65新加坡 -->
                        <select style="max-width:100%;" id = 'coupon_ZC_area'>
                          <option value = '86'>+86</option>
                          <option value = '82'>+82</option>
                          <option value = '65'>+65</option>
                        </select>
                      </div>

                      <input type="text" style="padding-left:74px;" placeholder="输入手机号" ng-class="{'phone':true,'e_act':is_phone}" ng-model="register_info.phone"  ng-focus = "hide_notice()">
                  <span class="notice">{{r_phone_num}}</span>
                </div>
                <div class="login_list" style="position:relative;">
                  <input id="pwd" type="password" placeholder="请输入密码" ng-class="{'phone':true,'e_act':is_phone}" ng-model="register_info.pwd" ng-focus = "hide_notice()">
                  <span class="show" ng-click="show_pwd()">{{show_pwd_value}}</span>
                  <span class="notice" >
                   {{r_pwd_num}}
                  </span>
                </div>
                <div class="login_list">
                  <input type="text"placeholder="输入验证码" ng-class="{'num':true,'e_act':true}"ng-model="register_info.code" ng-focus = "hide_notice()" >
                  <a ng-click="register_code($event)" ng-bind="captcha.paracont" class="test_btn">发送验证码</a>
                  <span class="notice" >{{r_pwd_login_res_code}} </span>
                </div>
                <div class="login_list">
                  <button type="button" id = "login_btn_1" ng-class="{'login_btn_def':true,'login_btn_act':true}" ng-click = "register()">注&nbsp;册</button>
                  <span class="notice" >
                    {{r_pwd_login_res}}
                  </span>
                </div>
              </form>
              <p class="change">
                  已是会员，<span style="color:#A58648;"ng-click="change_page(0)" >马上登录</span>
              </p>
            </div>
          </ion-content>
      </ion-modal-view>
    </script>
    <!--登录模块-->
  </ion-content>
</ion-view>